package com.project.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.common.validate.add;
import com.common.validate.edit;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.List;
import java.util.Map;


/**
 * 预算标准对象 dm_budget_standard
 *
 * @author baige
 * @date 2025-02-08
 */

@Data
@NoArgsConstructor
@AllArgsConstructor
@ApiModel("预算标准")
public class DmBudgetStandard extends TimeUserEntity implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("主键ID")
    @TableId(value = "id", type = IdType.ASSIGN_UUID)
    private String id;


    @ApiModelProperty("科研标准名称")
    @NotBlank(message = "科研标准名称不能为空", groups = {add.class, edit.class})
    private String name;


    @ApiModelProperty("备注")
    private String note;


    @ApiModelProperty("是否被项目预算使用状态(0:未使用  1:已使用)")
    @TableField(exist = false)
    private String isManageMatchFund;

    @ApiModelProperty("科目编号前缀")
    @NotBlank(message = "科目编号前缀不能为空", groups = {add.class, edit.class})
    private String prefix;

    /**
     * 项目分类
     */
    @Schema(description = "项目分类,zXProject->纵向,yfContract->横向,xJProject->校级",
            allowableValues = {"zXProject", "yfContract","xJProject"})
    private String projectClass;

    @Schema(description = "是否实行间接费(0:否,1:是)",
            allowableValues = {"0", "1"})
    @TableField("EXECUTE_INDIRECTFEE")
    private String executeIndirectFee;


    @ApiModelProperty("经费管理政策文件id")
    private String policyFileId;

    @ApiModelProperty("经费管理政策文件集合")
    @TableField(exist = false)
    private List<Map<String,String>> policyFileList;


    /**
     * 排序号
     */
    @TableField("ORDERID")
    private String orderId;

    /**
     * 本地名称
     */
    private String nameLocal;


}
